//
//  SVProgressHUD+Extension.m
//  Tradeaider
//
//  Created by 王方伟 on 16/8/20.
//  Copyright © 2016年 Shinyhub. All rights reserved.
//

#import "SVProgressHUD+Extension.h"

@implementation SVProgressHUD (Extension)
+ (void)show:(NSString *)text icon:(NSString *)icon{
    [SVProgressHUD setDefaultStyle:SVProgressHUDStyleDark];
    [self setFont:[UIFont systemFontOfSize:18]];
    [self setMinimumDismissTimeInterval:1.0];
    [self setRingRadius:10];
    [self showImage:[UIImage imageNamed:icon] status:text];
    
}


+ (void)showSuccess:(NSString *)success{
    [self show:success icon:@"success"];
}

+ (void)showError:(NSString *)error{
    [self show:error icon:@"error"];
}

+ (void)showInfo:(NSString *)info{
    [self show:info icon:nil];
}

+ (void)showNote:(NSString *)note{
    [self show:note icon:@"photo_info"];
}

+ (void)showMessage:(NSString *)message{
    [SVProgressHUD setDefaultStyle:SVProgressHUDStyleDark];
    [SVProgressHUD setDefaultMaskType:SVProgressHUDMaskTypeClear];
    [self setFont:[UIFont systemFontOfSize:18]];
    [self setRingRadius:10];
    [self showWithStatus:message];
}



@end
